package com.gzhryc.common.data.dto.echars;

import com.gzhryc.common.data.dto.echars.style.BackgroundStyle;

import java.util.List;

public class SeriesItem {

    public final static String Type_Bar = "bar";
    public final static String Type_Line = "line";
    public final static String Type_Map = "map";
    public final static String Type_Pie = "pie";

    public final static String MapType_China = "china";

    public final static String SelectedMode_Multiple = "multiple";

    private String name;
    private String type;

    private List<Object> data;

    //Pie
    private String radius;          //pie图表需，默认：50%
    private Emphasis emphasis;

    //Line
    private Boolean smooth;     //是否平整，line
    private ItemStyle itemStyle;    //可以填充Line围成的图像

    //Map
    private String mapType;
    private String selectedMode;

    //Bar
    private Boolean showBackground;     //是否显示背景，bar
    private BackgroundStyle backgroundStyle;

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getType() {
        return type;
    }

    public void setType(String type) {
        this.type = type;
    }

    public List<Object> getData() {
        return data;
    }

    public void setData(List<Object> data) {
        this.data = data;
    }

    public String getRadius() {
        return radius;
    }

    public void setRadius(String radius) {
        this.radius = radius;
    }

    public Emphasis getEmphasis() {
        return emphasis;
    }

    public void setEmphasis(Emphasis emphasis) {
        this.emphasis = emphasis;
    }

    public Boolean getSmooth() {
        return smooth;
    }

    public void setSmooth(Boolean smooth) {
        this.smooth = smooth;
    }

    public ItemStyle getItemStyle() {
        return itemStyle;
    }

    public void setItemStyle(ItemStyle itemStyle) {
        this.itemStyle = itemStyle;
    }

    public String getMapType() {
        return mapType;
    }

    public void setMapType(String mapType) {
        this.mapType = mapType;
    }

    public String getSelectedMode() {
        return selectedMode;
    }

    public void setSelectedMode(String selectedMode) {
        this.selectedMode = selectedMode;
    }

    public Boolean getShowBackground() {
        return showBackground;
    }

    public void setShowBackground(Boolean showBackground) {
        this.showBackground = showBackground;
    }

    public BackgroundStyle getBackgroundStyle() {
        return backgroundStyle;
    }

    public void setBackgroundStyle(BackgroundStyle backgroundStyle) {
        this.backgroundStyle = backgroundStyle;
    }

    public static class ItemStyle {

        private ItemStyleNormal normal;
        private ItemStyleEmphasis emphasis;

        public ItemStyleNormal getNormal() {
            return normal;
        }

        public void setNormal(ItemStyleNormal normal) {
            this.normal = normal;
        }

        public ItemStyleEmphasis getEmphasis() {
            return emphasis;
        }

        public void setEmphasis(ItemStyleEmphasis emphasis) {
            this.emphasis = emphasis;
        }
    }

    public static class ItemStyleNormal {

        private Label label;
        private AreaStyle areaStyle;

        public Label getLabel() {
            return label;
        }

        public void setLabel(Label label) {
            this.label = label;
        }

        public AreaStyle getAreaStyle() {
            return areaStyle;
        }

        public void setAreaStyle(AreaStyle areaStyle) {
            this.areaStyle = areaStyle;
        }
    }

    public static class ItemStyleEmphasis {

        private Label label;

        public Label getLabel() {
            return label;
        }

        public void setLabel(Label label) {
            this.label = label;
        }
    }

    public static class AreaStyle {

        private String type = "default";    //填充画面

        public String getType() {
            return type;
        }

        public void setType(String type) {
            this.type = type;
        }
    }

    public static class Label {

        private String formatter;
        private Boolean show = true;

        public String getFormatter() {
            return formatter;
        }

        public void setFormatter(String formatter) {
            this.formatter = formatter;
        }

        public Boolean getShow() {
            return show;
        }

        public void setShow(Boolean show) {
            this.show = show;
        }
    }
}
